#include <NewSoftSerial.h>
#include <OLED.h>

const int buttonPin = 8;

// Rx pin, Tx pin, reset pin
OLED oled(2, 3, 4);

// 
boolean wasPressed = false;

void setup() {
  // 
  oled.init();

  // 
  oled.setBackgroundColour(OLED_BLACK);

  // 
  oled.clearScreen();
}

void loop() {
  // 
  boolean isPressed = (digitalRead(buttonPin) == HIGH);

  // 
  if (!wasPressed && isPressed) {
    // 
    oled.displayVideoAnimationClipFromMemoryCard(
      0, 0, 128, 128, OLED_COLOR_16, 100, 30, 0x001000);
  } 

  // 
  wasPressed = isPressed;

  // 
  delay(10);
}

